<?php

namespace app\index\model;

use think\model\Merge;

class Member extends Merge
{
    // 设置主表名
    protected $table = 'bx_member';
    // 定义关联模型列表
    protected $relationModel = [
        // 给关联模型设置数据表
        'middle' => 'bx_member_middle'
    ];
    // 定义关联外键
    protected $fk = 'mid';
    protected $mapFields = [
        // 为混淆字段定义映射
        'm_id' => 'member.id',
        'middle_uid' => 'middle.uid',
    ];

}
